/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package assisisw.smartcal.persistencesubsystem;

import assisisw.smartcal.entitysubsystem.Calendar;
import assisisw.smartcal.entitysubsystem.Event;
import java.io.Serializable;
import javax.ejb.Remote;

/**
 *
 * @author Francesco
 */
@Remote
public interface IEventDAO extends Serializable
{

    // Instance Methods

    /**
     * @return
     */
    public Iterable < Event > findAll () ;
    
    /**
     * @param id
     * @return
     */
    public Event findById ( int id ) ;
    
    /**
     * @param calendar
     * @return
     * @throws IllegalArgumentException
     */
    public Iterable < Event > findByCalendar ( Calendar calendar ) ;
    
    /**
     * @param event
     * @throws IllegalArgumentException
     */
    public void insert ( Event event ) ;
    
    /**
     * @param event
     * @throws IllegalArgumentException
     */
    public void update ( Event event ) ;
    
    /**
     * @param event
     * @throws IllegalArgumentException
     */
    public void delete ( Event event ) ;
    
}
